package com.yc.yyds.dao;

import com.yc.yyds.util.DBHelper;

import java.sql.Date;


public class ArrangeDao {
    public void create(String  cinemaid, String movieid, String  starttime, String   endtime, String sell, String remainseats ){
        String sql="insert into arrange (cinemaid,movieid, starttime,endtime,sell,remainseats) values (?,?,?,?,?,?) ";
        DBHelper.update(sql,cinemaid,movieid, starttime,endtime,sell,remainseats);
    }
    public void modify(String ppjhid,String  cinemaid, String movieid, String  starttime, String   endtime, String sell, String remainseats ){
        String sql="update arrange set cinemaid=?,movieid=?,starttime=?,endtime=?,sell=?,remainseats=? where ppjhid=?";
        DBHelper.update(sql,cinemaid,movieid,starttime,endtime,sell,remainseats,ppjhid);
    }
    public void remove(String ppjhid){
        String sql="delete from arrange where ppjhid=?";
        DBHelper.update(sql,ppjhid);
    }

}
